/*
 * @Desc:
 * @author cheegon
 * @date 2024/6/6  下午1:37
**/
import { apiPost, apiGet } from '../config/apiConfig'

/**
 * 获取博客详情
 * @param id
 * @returns {Promise | Promise<unknown>}
 */
export const reqBlogInfo = (id) => apiGet(`/tourist/blog/${ id }`)
/**
 * 获取博客列表
 * @param params
 * @returns {Promise | Promise<unknown>}
 */
export const reqBlogList = (params) => apiGet('/tourist/getBlogList', params)
/**
 * 获取推荐的博客
 * @returns {Promise | Promise<unknown>}
 */
export const reqRecommendBlogList = () => apiGet('/tourist/getRecommendBlogList')
/**
 *
 * @param id
 * @returns {Promise | Promise<unknown>}
 */
export const reqReportView = (id) => apiGet(`/tourist/reportView/${ id }`)

/**
 * 获取使用最多的type列表
 * @param params
 * @returns {Promise | Promise<unknown>}
 */
export const reqTopTypeList = (params) => apiGet('/tourist/getTopTypeList',params)
/**
 * 获取type列表
 * @param params
 * @returns {Promise | Promise<unknown>}
 */
export const reqTypeList = (params) => apiGet('/tourist/getTypeList',params)
/**
 * 获取所有的type列表
 * @returns {Promise | Promise<unknown>}
 */
export const reqAllTypeList = () => apiGet('/tourist/getAllTypeList')
/**
 * 获取tag列表
 * @param params
 * @returns {Promise | Promise<unknown>}
 */
export const reqTagList = (params) => apiGet('/tourist/getTagList',params)
/**
 * 获取使用最多的tag列表
 * @param params
 * @returns {Promise | Promise<unknown>}
 */
export const reqTopTagList = (params) => apiGet('/tourist/getTopTagList',params)
/**
 * 获取所有的tag列表
 * @returns {Promise | Promise<unknown>}
 */
export const reqAllTagList = () => apiGet('/tourist/getAllTagList')
/**
 * 根据id获取tag
 * @param id
 * @returns {Promise | Promise<unknown>}
 */
export const reqTagById = (id) => apiGet(`/tourist/tag/${ id }`)
/**
 * 根据id获取type
 * @param id
 * @returns {Promise | Promise<unknown>}
 */
export const reqTypeById = (id) => apiGet(`/tourist/type/${ id }`)
/**
 * 留言列表
 * @param params
 * @returns {Promise | Promise<unknown>}
 */
export const reqMessagesList = (params) => apiGet('/tourist/messageList', params)
/**
 * 项目列表
 * @param params
 * @returns {Promise | Promise<unknown>}
 */
export const reqProjectList = () => apiGet('/tourist/projectList')
/**
 * 评论列表
 * @param params
 * @returns {Promise | Promise<unknown>}
 */
export const reqCommentList = (params) => apiGet('/tourist/commentList', params)
/**
 * 随笔列表
 * @returns {Promise | Promise<unknown>}
 */
export const reqEssayList = (params) => apiGet('/tourist/essayList',params)




export const reqNewBlog = (params) => apiGet('/tourist/footer/newblog', params)

export const reqSearch = (params) => apiGet('/tourist/search', params)

